<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="zh-CN">
<head>
<title>{$smarty.const.TITLE} - 考试界面 </title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="description" content="布尔教育 http://www.itbool.com" />
<link rel="stylesheet" href="{$smarty.const.Home_URL}css/index.css" type="text/css"/>
</head>
    <body>
    	<div id="container">
    		<div class="left">
    			<p>　</p>
    			<div class="name">
    				<span>姓名：{$student.name}</span> <br/>
    				<span>性别：{$student.sex}</span><br/>
    				<span>准考证号：{$student.t_number}</span><br/>
    				<span>身份证号：{$student.id_number}</span><br/>
    			</div>
    			<p>　</p>
    			<div id="clock">
    				<p>　</p>
    				<div id="timer">倒计时开始</div>
    			</div>
    		</div>
    		<div class="right">
    			<h1>《C语言程序设计》在线考试</h1>
                <p>　</p>
    			<span class="text-center" style="color:red;margin-left:16%;">
						为保证考试的公平公正性，在考试期间请勿人为刷新或关闭浏览器，否则该考生成绩直接记为0分。</span>
				<form action="{$smarty.const.__SELF__}" method="post" enctype="multipart/form-data">
					<div class="idTabs">一、选择题</div>
					<div class="tittle" style="margin-left:50px;width:800px;">
						<h4>1.单选题</h4>
						{foreach $que1 as $q1}
						<div class="num" style="border-bottom:1px solid red">第{$q1@iteration}题</div>
						<div class="con">{include file=$q1.content}</div>
						<label for="{$q1.id}"> 
							<input type="radio" name="{$q1.id}" value="A"> A、{$q1.select_a}
						</label><br/>
						<label for="{$q1.id}"> <input
								type="radio" name="{$q1.id}" value="B"> B、{$q1.select_b}
						</label><br/>
						<label for="{$q1.id}"> <input
								type="radio" name="{$q1.id}" value="C"> C、{$q1.select_c}
						</label><br/>
						<label for="{$q1.id}"> <input
								type="radio" name="{$q1.id}" value="D"> D、{$q1.select_d}
						</label>
						{/foreach}
					</div>
					<div class="tittle" style="margin-left:50px;width:800px;">
						<h4>2.多选题</h4>
						{foreach $que2 as $q2}
						<div class="num" style="border-bottom:1px solid red">第{$q2@iteration}题</div>
						<div class="con">{include file=$q2.content}</div>
						<label><input name="{$q2.id}[]" type="checkbox" value="A" />A、{$q2.select_a}</label> <br/>
						<label><input name="{$q2.id}[]" type="checkbox" value="B" />B、{$q2.select_b} </label> <br/>
						<label><input name="{$q2.id}[]" type="checkbox" value="C" /> C、{$q2.select_c} </label> <br/>
						<label><input name="{$q2.id}[]" type="checkbox" value="D" />D、{$q2.select_d}</label> <br/>
						{/foreach}
					</div>
					<div class="idTabs">二、填空题</div>
					<div class="tittle" style="margin-left:50px;width:800px;">
						<h4>1.概念填空题</h4>
						{foreach $que3 as $q3}
						<div class="con">({$q3@iteration}) {include file=$q3.content}<input type="text" name="{$q3.id}" style="BORDER-TOP: none;BORDER-RIGHT: none; BORDER-LEFT: none; BORDER-BOTTOM: 1px solid black;"/></div>
						{/foreach}
					</div>
					<div class="tittle" style="margin-left:50px;margin-bottom:10px;">
						<h4>2.程序填空题</h4>
						{foreach $que4 as $q4}
						<div class="con">({$q4@iteration}){include file=$q4.content}<input type="text" name="{$q4.id}" style="BORDER-TOP: none;BORDER-RIGHT: none; BORDER-LEFT: none; BORDER-BOTTOM: 1px solid black;"/></div>
						{/foreach}
					</div>
					<div class="idTabs">三、程序题</div>
					<div class="tittle" style="margin-left:50px;width:800px;">
						<h4>1.程序问答题</h4>
						{foreach $que5 as $q5}
						<div class="con">({$q5@iteration}){include file=$q5.content}</div>
						<textarea name="{$q5.id}" cols="83" rows="8" class="textArea" /></textarea>
						{/foreach}
					</div>
					<div class="tittle" style="margin-left:50px;width:800px;">
						<h4>2.程序编写题</h4>
						{foreach $que6 as $q6}
						<div class="con">{include file=$q6.content}</div>
						<textarea name="{$q6.id}" cols="83" rows="8" class="textArea" /></textarea>
						{/foreach}
					</div>
					<input type="submit" value="交卷" class="loginbtn" style="margin-top:10px;background-color:#0072c6;margin-left:49px;border-radius:2px;color:#fff;padding:6px 30px;"/>
					<p>　</p>
				</form>
    		</div>
    	</div>
<SCRIPT LANGUAGE="JavaScript">   
<!--   
	var maxtime = 60*120 //1小时，按秒计算   
	function CountDown(){   
		if(maxtime>=0){   
			minutes = Math.floor(maxtime/60);   
			seconds = Math.floor(maxtime%60);   
			msg = "距考试结束还有："+minutes+"分"+seconds+"秒";   
			document.all["timer"].innerHTML=msg;   
			if(maxtime == 5*60) alert('注意，还有5分钟!');   
			--maxtime;   
			}   
	else{   
		clearInterval(timer);   
		alert("时间到，考试已结束!");   
	}   
}   
timer = setInterval("CountDown()",1000);   

//-->   
</SCRIPT>
    </body>
</html>